<?php
/**
 * Q_Input tests
 */
class Tests_Q_Filter extends UnitTestCase {

    public $input, $data;
    
    public function setUp() {
    
        $this->data = array(
            'name'          => 'Willow',
            'email'         => 'ac.mattis@venenatis.edu',
            'state'         => 'Mississippi',
            'cousin'        => 'Jeannette',
            'girlfriend'    => 'Mikayla',
            'dogemail'      => 'purus.ac.tellus@Morbinonsapien.edu',
            'country'       => 'Cedarburg',
            'letters'       => 'LA',
            'numbers'       => '23234234',
            'empty'         => '',
	    'md[mu]'        => 'multilicious',
            'md[mi]'        => '',
            'neat!'         => 0,
        );
        $this->filters = new Q_Filter_Set;
    
    }
    public function tearDown() {
    
        // nothing to tear down
    
    }
    
    public function testFilterSingle() {
    
        $filter = new Mock_Q_Filter;
        $this->assertEqual($filter->doFilter($this->data['name']), 'TEST');
    
    }
    
    public function testFilterMulti() {
    
        $filter = new Mock_Q_Filter;
        $this->filters->add($filter, 'name');
        $data = $this->filters->filter($this->data);
        $this->assertEqual($data['name'], 'TEST');
    
    }
    

}